﻿<%@ Page Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeBehind="StockSearch.aspx.cs" Inherits="Ankin.EHBH.Web.Modules.StockManage.StockSearch" Title="医用耗材管理系统" %>
<%@ Register Assembly="Meta.Web" Namespace="Meta.Web.Controls" TagPrefix="mc" %>
<asp:Content ID="Content2" ContentPlaceHolderID="cphcenter" runat="server">

    <script src="../../js/jquery-1.3.2.min.js" type="text/javascript"></script>
    <script src="../../js/popup.js" type="text/javascript"></script>
   
    <script src="../../js/jquery.flexselect.js" type="text/javascript"></script>

    <script src="../../js/liquidmetal.js" type="text/javascript"></script>

    <script type="text/javascript">
      $(document).ready(function() {
        $("select[class*=flexselect]").flexselect();
        
        
        //获取供应商文本
        $('#ctl00_cphcenter_ddlSupply_flexselect').blur(function() 
        {var tt = $('#ctl00_cphcenter_ddlSupply_flexselect').attr('value');
        $('#ctl00_cphcenter_hdfSupply').attr('value',tt);
        })
        

        
        /*测试COOKIES*/
        if($.cookie('popupStatus')==1)
        {
            disablePopup();
            centerPopup();
            loadPopup();
        }
        //写Cookies
        $('#wCookies').click(function(){
		$.cookie('name', 'test11213',{expires: 7});				  
		});
		//读Cookies
		$('#rCookies').click(function(){
		var test = $.cookie('popupStatus');
		alert (test);
		});
		
		$('#rCookies1').click(function(){
		var test = $.cookie('popupStatus');
		alert (test);
		});
		//删除
		$('#dCookies').click(function(){
		$.cookie('popupStatus', '0',{expires: 7});							  
		});
		
      });




    </script>

    <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
            <td class="right-color">
                库存管理---库存查询</td>
        </tr>
    </table>
        
                <table width="100%" border="0" cellpadding="0" cellspacing="0" style="margin-top:14px;">
                    <tr>
                        <td class="bor bor-bg">
                            库存查询条件
                        </td>
                    </tr>
                    <tr>
                    <td class="bor">
                  <table width="100%" border="0" cellpadding="0" cellspacing="0" class="t1">
                  <tr>
                        <td align="right">
                            消耗品类别：</td>
                        <td colspan="3">
                            <asp:DropDownList ID="ddlPrimClass" runat="server" AutoPostBack="True" OnSelectedIndexChanged="ddlPrimClass_SelectedIndexChanged"
                                Width="182px">
                            </asp:DropDownList></td>
                        <td align="right">
                            二级类别：</td>
                        <td>
                            <asp:DropDownList ID="ddlSecClass" runat="server" Width="182">
                            </asp:DropDownList></td>
                    </tr>
                    <tr>
                        <td  align="right">
                            消耗品名称：</td>
                        <td colspan="3">
                            <asp:DropDownList ID="ddlExp_Name" runat="server" AutoPostBack="true" CssClass="flexselect"
                                Width="175px">
                            </asp:DropDownList><br />
                            <div style="display: none">
                                        <asp:TextBox ID="TxtExpName" Width="170" runat="server" OnTextChanged="TxtExpName_TextChanged" AutoPostBack="True"></asp:TextBox></div></td>
                        <td  align="right">
                            规格型号：</td>
                        <td>
                            <asp:DropDownList ID="ddlSpecs" runat="server" Width="182">
                            </asp:DropDownList></td>
                    </tr>
                    <tr>
                        <td  align="right">
                    消耗品代码：</td>
                        <td colspan="4">
                            <asp:TextBox ID="txtExpCode" runat="server" Width="175"></asp:TextBox></td>
                            <td>
                                <asp:Button ID="Button1" runat="server" Text="查询" CssClass="button"  OnClick="ButtonSearch_ServerClick"/>
                            <%--<input type="button" value="查询" id="ButtonSearch" style="width: 57px; height:25px; cursor:pointer;" class="button" onserverclick="ButtonSearch_ServerClick" runat="server" />--%></td>
                    </tr>
                </table>
            </td>
        </tr>
        </table>
                <table width="100%" border="0" cellpadding="0" cellspacing="0" style="margin-top:14px;">
                    <tr>
                        <td class="bor bor-bg">
                            库存列表</td>
                    </tr>
                    <tr>
                        <td class="bor" style="padding:13px;">
                            <asp:GridView ID="grdStorage" runat="server" Width="100%" AutoGenerateColumns="False" DataKeyNames="INFO_ID" AllowPaging="True"  CellPadding="4" ForeColor="Black"  OnPageIndexChanging="grdStorage_PageIndexChanging">
                            <RowStyle CssClass="gv-first-line"/>
                               <EmptyDataTemplate>
                                    <table width="100%" height="100">
                                        
                                        <tr>
                                            <td align="center" class="jg">
                                                对不起，没有找到任何相关记录
                                            </td>
                                        </tr>
                                    </table>
                                </EmptyDataTemplate>
                                <Columns>
                                    <asp:BoundField DataField="PRIM_CLASS_NAME" HeaderText="消耗品类别" />
                                    <asp:BoundField DataField="SEC_CLASS_NAME" HeaderText="二级类别" />
                                    <asp:BoundField DataField="EXP_CODE" HeaderText="消耗品代码" />
                                    <asp:BoundField DataField="EXP_NAME" HeaderText="消耗品名称" />
                                    <asp:BoundField DataField="SPECS" HeaderText="规格型号" />
                                    <asp:BoundField DataField="UNITS" HeaderText="单位" />
                                    <asp:BoundField DataField="QUAN" HeaderText="库存数量" />
                                    <asp:BoundField DataField="AMOUNT_BUY" HeaderText="采购金额" />
                                    <asp:BoundField DataField="AMOUNT_SELL" HeaderText="可售金额" />
                                    <asp:TemplateField HeaderText="详细">
                                      <ItemTemplate>
                                      <table width="57" border="0" cellspacing="0" cellpadding="0" align="center">
                                          <tr>
                                            <td height="25" align="center" class="button" style="padding-top:2px;">
                                        <a href='<%#"StockSearchDetail.aspx?INPUT_PARA_INFO_ID="+Eval( "INFO_ID")%>'>详细</a>
                                        </tr>
                                    </table>
                                      </ItemTemplate>
                                    </asp:TemplateField>                                   
                                </Columns>
                                   <PagerStyle CssClass="fy" />
                              <SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="Black" />
                              <HeaderStyle  CssClass="gv-head" />
                              <EditRowStyle BackColor="Black" />
                              <AlternatingRowStyle BackColor="White" />
                              <PagerSettings Mode="NumericFirstLast" FirstPageText="首页" LastPageText="末页"/>
                            </asp:GridView>
                            <br/>
                            <table width='100%'align="right">
                                <tr>
                                    <td style="font-weight: bold" align="center">采购总额: 
                                        <asp:Label ID="lblTotal" runat="server" Font-Bold="True" ForeColor="Red"></asp:Label></td>                                    
                                </tr>
                            </table>
                            
                        </td>
                    </tr>
                    </table>
           


</asp:Content>
